Skip to content

Instantly share code, notes, and snippets.

interfaces {
lo0 {
unit 0 {
family inet {
filter {
input-list [ discard-frags accept-single-hop-bfd-v4 accept-multi-hop-bfd-v4 accept-bgp-v4 accept-ospf2 accept-vrrpv3-v4 accept-established-v4 accept-common-services-v4 discard-all-v4 ];
}
}
family inet6 {
filter {
@DariuszMak
DariuszMak / yt-dlp.md
Last active May 10, 2024 17:44
YT-DLP

YT-DLP

Linux

sudo curl -L https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp -o /usr/local/bin/yt-dlp
sudo chmod a+rx /usr/local/bin/yt-dlp

Windows

#!/usr/bin/env ruby
# encoding: utf-8
require 'csv'
require 'dina'
Dina.config = {
authorization_url: 'https://dina.biodiversity.agr.gc.ca/auth',
endpoint_url: 'https://dina.biodiversity.agr.gc.ca/api',
server_name: 'dina-prod',
@davydany
davydany / IPTABLES-CHEATSHEET.md
Last active May 10, 2024 17:43
IP Tables (iptables) Cheat Sheet

IP Tables (iptables) Cheat Sheet

IPTables is the Firewall service that is available in a lot of different Linux Distributions. While modifiying it might seem daunting at first, this Cheat Sheet should be able to show you just how easy it is to use and how quickly you can be on your way mucking around with your firewall.

Resources

The following list is a great set of documentation for iptables. I used them to compile this documentation.

@nikitawootten
nikitawootten / nvidia-test-arion.nix
Created August 16, 2023 22:01
An Arion NixOS module that requests an NVIDIA GPU
{ ... }:
{
virtualisation.arion.projects.nvidia-test.settings.services.nvidia-test = {
service = {
image = "nvidia/cuda:12.2.0-base-ubuntu20.04";
command = "nvidia-smi";
};
out.service = {
deploy.resources.reservations.devices = [
{
@hecht1962
hecht1962 / ipstocrash.pl
Last active May 10, 2024 17:40
Convert an IPS crash report (.ips) to the legacy crash report format (.crash)
#!/usr/bin/perl
##
## This script converts an IPS crash report (.ips) to the legacy crash report format.
##
## The .ips file (JSON) is read from STDIN and the legacy crash report is written to
## STDOUT.
##
use strict;
@abhishtagatya
abhishtagatya / autoclip.py
Last active May 10, 2024 17:37
Automation Script to Edit Videos for TikTok using Python
# _____ _ _____ _ _
# | _ |_ _| |_ ___| | |_|___
# | | | | _| . | --| | | . |
# |__|__|___|_| |___|_____|_|_| _|
# |_|
#
# By Abhishta (github.com/abhishtagatya)
# pip install gTTs
# pip install moviepy
@mjnaderi
mjnaderi / install-arch.md
Last active May 10, 2024 17:36 — forked from mattiaslundberg/arch-linux-install
Installing Arch Linux with Full Disk Encryption (LVM on LUKS)

Installing Arch Linux with Full Disk Encryption

If you're aiming for a seamless Arch Linux installation in UEFI mode, follow along as this guide will walk you through the process step by step. We'll be using LUKS (Linux Unified Key Setup) and LVM (Logical Volume Manager) partitions on LUKS to achieve full disk encryption.

Note: I have updated this doc for UEFI mode. For those with BIOS/MBR systems, you can refer to the previous version, but keep in mind that it might be outdated and no longer accurate.

If you're only interested in installing Linux and not setting up dual boot with Windows, feel free to skip the Windows-related sections.

@jimmyca15
jimmyca15 / Certificate.cs
Created December 13, 2017 02:10
Code for creating a self signed certificate in .NET Core using CertEnroll APIs
namespace CreateCert
{
using System;
using System.Collections.Generic;
using System.Security.Cryptography.X509Certificates;
using System.Threading.Tasks;
class Certificate
{
public static async Task<X509Certificate2> Create(string subject, string friendlyName, IEnumerable<string> alternativeNames)